package com.zifeng.exception;

public class ErrorCodeAndMsg {

    // 通用错误
    public static final int SYSTEM_ERROR_CODE = 1000;
    public static final String SYSTEM_ERROR_MSG = "系统异常，请稍后重试";

    public static final int PARAM_ERROR_CODE = 1001;
    public static final String PARAM_ERROR_MSG = "参数错误";

    // 用户相关错误
    public static final int USER_NOT_FOUND_CODE = 2001;
    public static final String USER_NOT_FOUND_MSG = "用户不存在";

    public static final int USER_LOGIN_FAILED_CODE = 2002;
    public static final String USER_LOGIN_FAILED_MSG = "用户登录失败";

    public static final int USER_ACCOUNT_MONEY_NOT_ENOUGH_CODE = 2003;
    public static final String USER_ACCOUNT_MONEY_NOT_ENOUGH_MSG = "账户余额不足";

    // 订单相关错误
    public static final int ORDER_NOT_FOUND_CODE = 3001;
    public static final String ORDER_NOT_FOUND_MSG = "订单不存在";

    public static final int ORDER_CREATE_FAILED_CODE = 3002;
    public static final String ORDER_CREATE_FAILED_MSG = "订单创建失败";

    public static final int ORDER_FEIGN_ADD_FAIL_CODE = 3003;
    public static final String ORDER_FEIGN_ADD_FAIL_MSG = "远程调用创建订单和区块失败";

    public static final int ORDER_FEIGN_SELECT_BY_ID_FAIL_CODE = 3004;
    public static final String ORDER_FEIGN_SELECT_BY_ID_FAIL_MSG = "远程调用查询订单失败";

    // 区块链相关错误
    public static final int BLOCK_CREATE_FAIL_CODE = 4001;
    public static final String BLOCK_CREATE_FAIL_MSG = "创建区块失败";

    public static final int BLOCK_FEIGN_CREATE_FAIL_CODE = 4002;
    public static final String BLOCK_FEIGN_CREATE_FAIL_MSG = "远程调用创建区块失败";

    // 任务委托相关错误
    public static final int ASSIGNMENT_FEIGN_GET_FINISHED_LIST_FAIL_CODE = 5001;
    public static final String ASSIGNMENT_FEIGN_GET_FINISHED_LIST_FAIL_MSG = "远程调用获取已完成委托列表失败";

    public static final int ASSIGNMENT_FEIGN_UPDATE_FAIL_CODE = 5002;
    public static final String ASSIGNMENT_FEIGN_UPDATE_FAIL_MSG = "远程调用更新任务失败";
}

